import VueRouter from 'vue-router'
import App from './App.vue'
import HomePage from './components/tabbar_bottom/HomePage.vue'
    import NewsList from './components/news/NewsList.vue'
        import NewsDetail from './components/news/NewsDetail.vue'
    import PictureShare from './components/news/PictureShare.vue'
    import BuyGoods from './components/news/BuyGoods.vue'
    import Comment from './components/news/Comment.vue'
    import Video from './components/news/Video.vue'
    import LinkMe from './components/news/LinkMe.vue'
import VipPage from './components/tabbar_bottom/VipPage.vue'
import ShopPage from './components/tabbar_bottom/ShopPage.vue'
import SearchPage from './components/tabbar_bottom/SearchPage.vue'

var router = new VueRouter({
    routes: [
        { path: '/', redirect: '/App/HomePage' },
        { 
            path: '/App', 
            component: App,
            children: [
                { path: 'HomePage', component: HomePage },
                { path: 'VipPage', component: VipPage },
                { path: 'ShopPage', component: ShopPage },
                { path: 'SearchPage', component: SearchPage },
                { path: 'HomePage/NewsList', component: NewsList },
                { path: 'HomePage/PictureShare', component: PictureShare },
                { path: 'HomePage/BuyGoods', component: BuyGoods },
                { path: 'HomePage/Comment', component: Comment },
                { path: 'HomePage/Video', component: Video },
                { path: 'HomePage/LinkMe', component: LinkMe },
                { path: 'HomePage/NewsList/NewsDetail/:name', component: NewsDetail }
            ]
        },
    ],
    linkActiveClass: 'active'
})

export default router